package com.qupeng.demo.kafka.kafkaspringbootproducer.admin.model;

import lombok.Data;
import org.apache.kafka.clients.admin.MemberDescription;
import org.apache.kafka.common.ConsumerGroupState;
import org.apache.kafka.common.acl.AclOperation;

import java.util.Collection;
import java.util.Set;

@Data
public class ConsumerGroupDescribe {
    private String groupId;
    private boolean isSimpleConsumerGroup;
    private Collection<MemberDescription> members;
    private String partitionAssignor;
    private ConsumerGroupState state;
    private Coordinator coordinator = new Coordinator();
    private Set<AclOperation> authorizedOperations;

    public String getGroupId() {
        return groupId;
    }

    public boolean isSimpleConsumerGroup() {
        return isSimpleConsumerGroup;
    }

    public Collection<MemberDescription> getMembers() {
        return members;
    }

    public String getPartitionAssignor() {
        return partitionAssignor;
    }

    public ConsumerGroupState getState() {
        return state;
    }

    public Coordinator getCoordinator() {
        return coordinator;
    }

    public Set<AclOperation> getAuthorizedOperations() {
        return authorizedOperations;
    }
}
